package com.example.mqconsumer.config;

import org.springframework.amqp.core.Binding;
import org.springframework.amqp.core.BindingBuilder;
import org.springframework.amqp.core.DirectExchange;
import org.springframework.amqp.core.Queue;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class RabbitConfig {
/*    //队列
    @Bean
    public Queue testQueue() {
        return new Queue("testQueue", true);
    }
    //交换机
    @Bean
    DirectExchange directExchange() {
        return new DirectExchange("testExchange", true, false);
    }
    //绑定
    @Bean
    Binding bindingDirect() {
        return BindingBuilder.bind(testQueue()).to(directExchange()).with("TestDirectRouting");
    }*/
}
